package com.example.demo1.controller;


import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

//@RestController == @Controller + @ResponseBody
@Controller
public class HelloController {
    @ResponseBody
    @RequestMapping("/first")
    public String index() {
        System.out.println(" firstController is running! ");
        return "Welcome to Spring Boot Application!";
    }
}
